namespace Cos.Core.NHibernate
{
    public class ArchiveElementDataModel
    {
        public virtual long Id { get; set; }

        public virtual int ArchivePageId { get; set; }

        public virtual int DataTypeId { get; set; }

        public virtual string ElementFile { get; set; }

        public virtual string ElementValue { get; set; }

        public virtual string PartName { get; set; }

        public override bool Equals(object obj)
        {
            if (obj == null)
            {
                return false;
            }

            var model = obj as ArchiveElementDataModel;

            return model != null && this.Id == model.Id;
        }

        public override int GetHashCode()
        {
            return this.Id.GetHashCode();
        }
    }
}